package test04;

public class Reg2 {
    public static void main(String[] args) {
        String str="{123}";
        String reg="[{]{1}[0-9]*[}]{1}";
        System.out.println(str.matches(reg));
    }
}
